package com.coders.JavaCollections;

import java.util.ArrayList;
import java.util.List;

public class ArrayExmple {
	public static void main(String args[])
	{
	 List al = new ArrayList();
	 al.add("Hello");
	 al.add("Array");
	 al.add("list");
	 System.out.println(" Charater Array"+al);
	 List al2 =new ArrayList();
	 for(int i=0;i<5;i++){
		 al2.add(new Integer(i));
		 
	 }
	 System.out.println("Arraylist of Integers"+al2);
	 System.out.println("Array List --->");
	 for(int j=0;j<al.size();j++){
		 System.out.print(al.get(j)+" ,"); 
		 
	 }
		System.out.println();
	int index= al.indexOf("Array");
	System.out.println("Index of element'Array' from Arraylist is :"+index);

	}

}
